package com.ysd.lis.controller.bac;


import com.ysd.common.Result;
import com.ysd.lis.controller.pub.BaseController;
import com.ysd.lis.entity.bac.BacUnionColoCount;
import com.ysd.lis.entity.sta.StaColonyCount;
import com.ysd.lis.service.bac.BacUnionColoCountService;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * <p>
 * 前端控制器
 * </p>
 *
 * @author cfz
 * @since 2024-04-07
 */
@RestController
@RequestMapping("/api/bac/bac-union-colo-count")
public class BacUnionColoCountController extends BaseController {
    @Autowired
    BacUnionColoCountService bacUnionColoCountService;

    @ApiOperation("查询")
    @GetMapping("/findBacUnionColoCountList")
    public Result findBacUnionColoCountList(BacUnionColoCount bacUnionColoCount) {
        return bacUnionColoCountService.findBacUnionColoCountList(bacUnionColoCount);
    }

    @ApiOperation("增加")
    @PostMapping("/addBacUnionColoCount")
    public Result addBacUnionColoCount(@RequestBody BacUnionColoCount bacUnionColoCount) {
        return bacUnionColoCountService.addBacUnionColoCount(bacUnionColoCount);
    }

    @ApiOperation("删除")
    @PostMapping("/deleteBacUnionColoCount")
    public Result deleteBacUnionColoCount(@RequestBody BacUnionColoCount bacUnionColoCount) {
        return bacUnionColoCountService.deleteBacUnionColoCount(bacUnionColoCount);
    }

    @ApiOperation("修改")
    @PostMapping("/updateBacUnionColoCount")
    public Result updateBacUnionColoCount(@RequestBody BacUnionColoCount bacUnionColoCount) {
        return bacUnionColoCountService.updateBacUnionColoCount(bacUnionColoCount);
    }

    @ApiOperation("标准库创建")
    @PostMapping("/staDataUnionColoCount")
    public Result staDataUnionColoCount(@RequestBody List<StaColonyCount> staColonyCounts) {
        return bacUnionColoCountService.staDataUnionColoCount(staColonyCounts);
    }
}
